<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
    <style>
        .inner {
            width: 100px;
            overflow: hidden;
            background: blue;
        }
        
        .inner::after {
            content: "";
            margin-top: 100%;
            display: block;
        }
    </style>
</head>

<body>
    <div class="outer">
        <div class="inner"></div>
    </div>
</body>

</html>